<%@ Page Title="" Language="C#" MasterPageFile="~/SitePagePopUp.Master" AutoEventWireup="true" CodeBehind="Category.aspx.cs" Inherits="TranTekBE.Category" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="BodyPopupContent" runat="server">
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
    <ContentTemplate>
        <table style="width:100%">
            <tr>
                <td colspan="2" class="msgError"><asp:Literal ID="ltError" runat="server" />&nbsp;</td>
            </tr>
            <tr>
                <td class="tdRightM" style="width:20%">Category:<br /><asp:Literal ID="ltCategoryNameErr" runat="server" /></td>
                <td class="tdLeftM" style="width:80%"><asp:TextBox ID="txtCategoryName" runat="server" Width="300px" MaxLength="100" /> <span class="msgError">*</span></td>
            </tr>
            <tr>
                <td class="tdRightM">Active:</td>
                <td class="tdLeftM">
                    <asp:RadioButtonList ID="rblStatus" runat="server" RepeatDirection="Horizontal">
                        <asp:ListItem Text="Yes" Value="1" Selected="True" />
                        <asp:ListItem Text="No" Value="0" />
                    </asp:RadioButtonList>
                </td>
            </tr>
            <tr>
                <td class="tdRightT">Comments:</td>
                <td class="tdLeftM"><asp:TextBox ID="txtComments" runat="server" TextMode="MultiLine" Height="70px" Width="300px" MaxLength="256" /></td>
            </tr>
            <tr>
                <td colspan="2" class="tdCenterM"><asp:Button ID="btnSubmit" Text="Ok" 
                        runat="server" onclick="btnSubmit_Click" Width="70px" /> <button id="btnCancel" style="width:70px;" type="button">Cancel</button></td>
            </tr>
        </table>
        <script type="text/javascript">
            function LoadJS(){
                $("#btnCancel").on("click", function() {
                    window.parent.CloseDialog();
                });

                $("input[id*='txtCategoryName']").on("focus", function() {
                    $(this).parent().parent().find('.msgErrorSmall').hide();
                });
            }
        </script>
    </ContentTemplate>
</asp:UpdatePanel>
</asp:Content>